



*** Baseline regressions (table 1, column (1)), Reduced form and IV regressions (table 2) and Mediator analysis (table 3) Province level

clear all 



use "/... domenechsanchezcuenca_BJPS/domenechsanchezcuenca_province_reg.dta"


* LEFTvotosinreg: is the share of votes going to Leftist parties, excluding Nationalist Leftist parties 

* LEFTvotosconreg: is the share of votes going to Leftist parties, including Nationalist Leftist parties 

* lanineq_1860: our measure of past agrarian inequality, proportion of landless rural labourers in the gainfully occupied in agriculture

* analfa1860: percentage illiterate, 1860 Population Census

* histregion: dummy variable taking value 1 if province belongs to Catalonia, Basque Country or Galicia.

* i.year: dummy variable for each election (base category is the 1977 election)

* altitud: altitude of the capital city of the province

* _CX, _CY: coordinates of the centroid of the province, longitude and latitude

* provid: identifier for each province 

* Popular Front: % share vote going to Popular Front in the 1936 general election

* structural_change_1930_1970: % change in agrarian population from 1930 to 1970. 


replace leftrepression=0 if leftrepression==.

gen asin_leftrepression=asinh(leftrepression)

gen asin_rightrepression=asinh(rightrepression)


gen PopularFront_Right=PopularFront*asin_rightrepression

gen PopularFront_Left=PopularFront*asin_leftrepression



xtset provid year




**** Table 1 column (1) Baseline regression, province level, pooled OLS with clustered standard errors at the province level 

reg LEFTvotosinreg lanineq_1860  histregion  i.year  altitud  _CX _CY, vce(cluster provid)



**** Table 2 

**** Column (1) table 2 Reduced form

reg LEFTvotosinreg reconquest analfa1860  histregion  i.year  altitud  _CX _CY, vce(cluster provid)


**** Columns (2) and (3) table 2 IV regression

ivregress 2sls LEFTvotosinreg analfa1860 histregion i.year altitud _CX _CY (lanineq_1860 =reconquest), vce(cluster provid)

ivregress 2sls LEFTvotosinreg analfa1860 histregion i.year altitud _CX _CY (lanineq_1860 =reconquest), first vce(robust)




**** Table 3

**** columns (1)-(3) table 3, with agrarian_inequality, 1860



reg LEFTvotosinreg lanineq_1860 PopularFront asin_rightrepression histregion i.year  altitud _CX _CY, vce(cluster provid)

reg LEFTvotosinreg lanineq_1860 Unemp Industry Education histregion i.year  altitud _CX _CY, vce(cluster provid)



**** Column (2) table 3. Channel Poverty, demeaning POPULAR FRONT and Rightist repression during Civil War

reg LEFTvotosinreg lanineq_1860  PopularFront asin_rightrepression structural_change_1930_1970   histregion i.year  altitud _CX _CY, vce(cluster provid)

 
gen coef1=_b[PopularFront] 

gen coef2=_b[asin_rightrepression]


       **** g-estimate 

gen LEFTvoto_tilde1=LEFTvotosinreg - (coef1*PopularFront)-(coef2*asin_rightrepression)


set seed 12345

bootstrap _b[lanineq_1860], size(550) reps(1000): reg LEFTvoto_tilde1 lanineq_1860  histregion i.year altitud _CX _CY



**** Column (4) table 3. Channel Popular Front, demeaning Unemployment, Industry 

reg LEFTvotosinreg lanineq_1860  Unemp Industry Education structural_change_1930_1970   histregion i.year  altitud _CX _CY, vce(cluster provid)

gen coef3=_b[Unemp] 

gen coef4=_b[Industry]

gen coef5=_b[Education]

       
	   
	   **** g-estimate

gen LEFTvoto_tilde2=LEFTvotosinreg - (coef3*Unemp) - (coef4*Industry) - (coef5*Education)



set seed 12345

bootstrap _b[lanineq_1860], size(550) reps(1000): reg LEFTvoto_tilde2 lanineq_1860  histregion i.year altitud _CX _CY	   
	   
	   
	   

